package com.yanqu.road.server.cmd.activity.xiuxian.cross;

import com.yanqu.road.message.YanQuMessage;
import com.yanqu.road.pb.activity.XiuXianProto;
import com.yanqu.road.pb.union.cross.CrossUnionActivityTaskProto;
import com.yanqu.road.server.cmd.base.AbstractCommand;
import com.yanqu.road.server.command.Cmd;
import com.yanqu.road.server.command.Command;
import com.yanqu.road.server.gameplayer.GamePlayer;
import com.yanqu.road.server.gameplayer.module.activity.xiuxian.XiuXianModule;
import com.yanqu.road.server.manger.activity.UnionActivityTaskMgr;
import com.yanqu.road.server.manger.activity.xiuxian.XiuXianMgr;
import com.yanqu.road.server.protocol.GameProtocol;
import io.netty.channel.ChannelHandlerContext;

import java.util.List;

@Cmd(code = GameProtocol.S_XIU_XIAN_SYNC_SECT_ENERGY_FROM_CROSS, desc = "跨服同步宗门体力")
public class XiuXianSyncSectEnergyFromCrossCmd implements Command {

    @Override
    public void execute(ChannelHandlerContext ctx, YanQuMessage packet) throws Exception {
        XiuXianProto.CrossXiuXianSyncCampEnergyRespMsg reqMsg = XiuXianProto.CrossXiuXianSyncCampEnergyRespMsg.parseFrom(packet.getBytes());
        XiuXianMgr.syncSectEnergy(reqMsg);
    }
}